package mymyoux.io.sockets.servers.mserverClasses
{

	public class Peoples
	{
		protected var _peoples:Vector.<People>;
		protected var _ids:Vector.<uint>;
		public function Peoples()
		{
			_peoples = new Vector.<People>();
			_ids = new Vector.<uint>();
		}
		public function contains(id:uint):Boolean
		{
			return _ids.indexOf(id) > -1;
		}
		public function add(people:People):void
		{
			_peoples.push(people);
			_ids.push(people.id);
		}
		public function rem(people:People):void
		{
			if(contains(people.id))
			{
				_peoples.splice(_ids.indexOf(people.id), 1);
			}
		}
		public function get length():uint
		{
			return _ids.length;
		}
	}
}